package com.ufinity.estimation.persistence.domain;

import java.util.HashSet;
import java.util.Set;

/**
 * 
 * Description of the class
 * 
 * @author lxt
 * @version 1.0
 * @since 2011-4-7
 */
public class User implements java.io.Serializable {

    /**
     * serialVersionUID long
     */
    private static final long serialVersionUID = 5037914060145702997L;

    private Long              id;

    private String            username;

    private String            name;

    private String            password;

    private UserType          userType;

    private String            userTypeName;

    private Set<Project>      projects         = new HashSet<Project>(0);

    private Set<Resource>     resources        = new HashSet<Resource>(0);

    // add the Set resource in order to get resources
    public Set<Resource> getResources() {
        return resources;
    }

    public void setResources(Set<Resource> resources) {
        this.resources = resources;
    }

    public String getUserTypeName() {
        return userTypeName;
    }

    public void setUserTypeName(String userTypeName) {
        this.userTypeName = userTypeName;
    }

    public Long getId() {
        return this.id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public UserType getUserType() {
        return this.userType;
    }

    public void setUserType(UserType userType) {
        this.userType = userType;
    }

    public String getUsername() {
        return this.username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getName() {
        return this.name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPassword() {
        return this.password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public Set<Project> getProjects() {
        return this.projects;
    }

    public void setProjects(Set<Project> projects) {
        this.projects = projects;
    }
}
